Struct isotope_repl::IsotopeHelper [−][src]
pub struct IsotopeHelper { /* fields omitted */ }
Expand description
A helper for isotope
input code.
Implementations
Trait Implementations
Takes the currently edited line
with the cursor pos
ition and
returns the start position and the completion candidates for the
partial word to be completed. Read more
Takes the currently edited line
with the cursor pos
ition and
returns the highlighted version (with ANSI color). Read more
fn highlight_prompt<'b, 's, 'p>(
&'s self,
prompt: &'p str,
default: bool
) -> Cow<'b, str> where
's: 'b,
'p: 'b,
fn highlight_prompt<'b, 's, 'p>(
&'s self,
prompt: &'p str,
default: bool
) -> Cow<'b, str> where
's: 'b,
'p: 'b,
Takes the prompt
and
returns the highlighted version (with ANSI color). Read more
fn highlight_hint(&self, hint: &'h str) -> Cow<'h, str>
fn highlight_hint(&self, hint: &'h str) -> Cow<'h, str>
Takes the hint
and
returns the highlighted version (with ANSI color). Read more
fn highlight_candidate(
&self,
candidate: &'c str,
completion: CompletionType
) -> Cow<'c, str>
fn highlight_candidate(
&self,
candidate: &'c str,
completion: CompletionType
) -> Cow<'c, str>
Takes the completion candidate
and
returns the highlighted version (with ANSI color). Read more
fn highlight_char(&self, line: &str, pos: usize) -> bool
fn highlight_char(&self, line: &str, pos: usize) -> bool
Tells if line
needs to be highlighted when a specific char is typed or
when cursor is moved under a specific char. Read more
Takes the currently edited input
and returns a
ValidationResult
indicating whether it is valid or not along
with an option message to display about the result. The most
common validity check to implement is probably whether the
input is complete or not, for instance ensuring that all
delimiters are fully balanced. Read more
fn validate_while_typing(&self) -> bool
fn validate_while_typing(&self) -> bool
Configure whether validation is performed while typing or only when user presses the Enter key. Read more